Video encoding is a time consuming and computationally intensive task. For example, it can take a few hours to encode a high-definition (HD) movie as H.264 or H.265 format. Most existing video encoding algorithms divide complete video into different groups of picture (GOPs), and use motion estimation and motion compensation algorithms to calculate motion vectors, then calculate the differences of adjacent pictures and encode them to achieve maximum compression ratio. Thus, one video's encoding time heavily depends on the duration of the video. In some cases, multi-pass encoding, also known as 2-pass or 3-pass encoding, is adopted to achieve better compression quality and accurate rate control; however, this increases the duration of time to complete the encoding process.